package com.ocom.nettyxf.client;

import com.ocom.common.constant.AiotUrl;
import com.ocom.common.resp.RespMachMessage;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(value = "aiot")
public interface AiotFeignService {

    //获取设备同步信息标志
    @GetMapping(AiotUrl.URL_Aiot_GetDeviceState)
    public RespMachMessage getDeviceState(@RequestParam("machNo")String machNo);

    @GetMapping(AiotUrl.URL_Aiot_GetDeviceFlag)
    public RespMachMessage getDeviceFlag(@RequestParam("machNo")String machNo,@RequestParam("versionCode")String versionCode);


    @PostMapping(AiotUrl.URLP_AIOT_getXfBinData)
    public RespMachMessage getXfBinData(@RequestParam("companyId")Long companyId, @RequestParam("machNo")String machNo,@RequestParam("lastBlockNum") Integer lastBlockNum);

    @PostMapping(AiotUrl.URLP_AIOT_changeXfBinDataState)
    public RespMachMessage changeXfBinDataState(@RequestParam("companyId")Long companyId,@RequestParam("machNo") String machNo,@RequestParam("jobId") Integer jobId);


}
